package tgc.edu.exam.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import tgc.edu.exam.custom.CommonService;
import tgc.edu.exam.entity.SysRole;
import tgc.edu.exam.repository.SysRoleRepository;


@Service
public class SysRoleService extends CommonService<SysRole, Integer>{

	@Autowired
	private SysRoleRepository dao;
	
	public SysRole findByCode(String string) {
		return dao.findByCode(string);
	}
	public List<SysRole> findByParentIsNull() {
		return dao.findByParentIsNull();
	}

	public SysRole findByName(String role) {
		// TODO Auto-generated method stub
		return dao.findByName(role);
	}
}
